/**
 * jims
 */
package com.jims.master.modules.drug.entity;

import org.hibernate.validator.constraints.Length;

import com.jims.master.common.persistence.DataEntity;

import java.beans.Transient;
import java.util.Date;
import java.util.List;

/**
 * 药品采购计划Entity
 * @author DT
 * @version 2017-03-22
 */
public class DrugBuyPlan extends DataEntity<DrugBuyPlan> {
	
	private static final long serialVersionUID = 1L;
	private String infoId;			//药品信息ID
	private String purchaseOrder;		// 采购序号
	private String drugCode;		// 药品编码
	private String drugName;		// 药品名称
	private String vedorName;		// 生产厂商
	private String supplierName;		// 采购供应商
	private String packageSpec;		// 规格
	private String packageUnit;		// 单位
	private String costPrice;		// 进货价
	private String plannedSelling;		// 计划数量
	private String plannedAmount;		// 计划金额
	private String warehouseKeeper;		// 仓管员
	private String purchaseSelling;		// 采购数量
	private String purchaseAmount;		// 采购金额
	private String buyer;		// 采购员
	private String drugForm;		// 剂型
    private String auditSelling;    //审核数量
    private String purchaseNumber;//采购单号
    private String storageDept;//库存单位
    private String stateFlag;        //状态标志 0-保存成功，1-调整，2-审核，3-执行,4-入库
	private Date expireDate;		// 有效期
	@Transient
	public Date getExpireDate() {
		return expireDate;
	}
	@Transient
	public void setExpireDate(Date expireDate) {
		this.expireDate = expireDate;
	}

	private DrugNameDict drugNameDict;   //药品名称字典  --获取剂型
    private DrugPrice drugPrice;  //药品价格 --显示药品售价
    private DrugStock drugStock;   //库存表 --显示库存
    private Double monthUsed;    //月消耗量
    private String minUnit;
    private String batchNo;    //药品采购入库所需批号
    private String supplierId;

    List<DrugBuyPlan> drugBuyPlanList;

    public List<DrugBuyPlan> getDrugBuyPlanList() {
        return drugBuyPlanList;
    }

    public void setDrugBuyPlanList(List<DrugBuyPlan> drugBuyPlanList) {
        this.drugBuyPlanList = drugBuyPlanList;
    }

    public String getPurchaseNumber() {
		return purchaseNumber;
	}

	public void setPurchaseNumber(String purchaseNumber) {
		this.purchaseNumber = purchaseNumber;
	}

	public String getStorageDept() {
		return storageDept;
	}

	public void setStorageDept(String storageDept) {
		this.storageDept = storageDept;
	}

	public String getAuditSelling() {
		return auditSelling;
	}

	public void setAuditSelling(String auditSelling) {
		this.auditSelling = auditSelling;
	}

	public String getStateFlag() {
		return stateFlag;
	}

	public void setStateFlag(String stateFlag) {
		this.stateFlag = stateFlag;
	}

	public String getInfoId() {
		return infoId;
	}

	public void setInfoId(String infoId) {
		this.infoId = infoId;
	}
	public DrugBuyPlan() {
		super();
	}

	public DrugBuyPlan(String id){
		super(id);
	}

	@Length(min=1, max=32, message="采购序号长度必须介于 1 和 32 之间")
	public String getPurchaseOrder() {
		return purchaseOrder;
	}

	public void setPurchaseOrder(String purchaseOrder) {
		this.purchaseOrder = purchaseOrder;
	}

	@Length(min=1, max=32, message="药品编码长度必须介于 1 和 32 之间")
	public String getDrugCode() {
		return drugCode;
	}

	public void setDrugCode(String drugCode) {
		this.drugCode = drugCode;
	}

	@Length(min=1, max=100, message="药品名称长度必须介于 1 和 100 之间")
	public String getDrugName() {
		return drugName;
	}

	public void setDrugName(String drugName) {
		this.drugName = drugName;
	}

	@Length(min=1, max=40, message="生产厂商长度必须介于 1 和 40 之间")
	public String getVedorName() {
		return vedorName;
	}

	public void setVedorName(String vedorName) {
		this.vedorName = vedorName;
	}
	
	@Length(min=1, max=40, message="采购供应商长度必须介于 1 和 40 之间")
	public String getSupplierName() {
		return supplierName;
	}

	public void setSupplierName(String supplierName) {
		this.supplierName = supplierName;
	}

	@Length(min=1, max=20, message="规格长度必须介于 1 和 20 之间")
	public String getPackageSpec() {
		return packageSpec;
	}

	public void setPackageSpec(String packageSpec) {
		this.packageSpec = packageSpec;
	}

	@Length(min=1, max=8, message="单位长度必须介于 1 和 8 之间")
	public String getPackageUnit() {
		return packageUnit;
	}

	public void setPackageUnit(String packageUnit) {
		this.packageUnit = packageUnit;
	}
	
	public String getCostPrice() {
		return costPrice;
	}

	public void setCostPrice(String costPrice) {
		this.costPrice = costPrice;
	}
	
	@Length(min=0, max=11, message="计划数量长度必须介于 0 和 11 之间")
	public String getPlannedSelling() {
		return plannedSelling;
	}

	public void setPlannedSelling(String plannedSelling) {
		this.plannedSelling = plannedSelling;
	}
	
	public String getPlannedAmount() {
		return plannedAmount;
	}

	public void setPlannedAmount(String plannedAmount) {
		this.plannedAmount = plannedAmount;
	}
	
	@Length(min=0, max=20, message="仓管员长度必须介于 0 和 20 之间")
	public String getWarehouseKeeper() {
		return warehouseKeeper;
	}

	public void setWarehouseKeeper(String warehouseKeeper) {
		this.warehouseKeeper = warehouseKeeper;
	}
	
	@Length(min=0, max=11, message="采购数量长度必须介于 0 和 11 之间")
	public String getPurchaseSelling() {
		return purchaseSelling;
	}

	public void setPurchaseSelling(String purchaseSelling) {
		this.purchaseSelling = purchaseSelling;
	}
	
	public String getPurchaseAmount() {
		return purchaseAmount;
	}

	public void setPurchaseAmount(String purchaseAmount) {
		this.purchaseAmount = purchaseAmount;
	}
	
	@Length(min=0, max=64, message="采购员长度必须介于 0 和 64 之间")
	public String getBuyer() {
		return buyer;
	}

	public void setBuyer(String buyer) {
		this.buyer = buyer;
	}

	@Length(min=0, max=20, message="剂型长度必须介于 0 和 20 之间")
	public String getDrugForm() {
		return drugForm;
	}

	public void setDrugForm(String drugForm) {
		this.drugForm = drugForm;
	}

    public DrugNameDict getDrugNameDict() {
        return drugNameDict;
    }

    public void setDrugNameDict(DrugNameDict drugNameDict) {
        this.drugNameDict = drugNameDict;
    }

    public DrugPrice getDrugPrice() {
        return drugPrice;
    }

    public void setDrugPrice(DrugPrice drugPrice) {
        this.drugPrice = drugPrice;
    }

    public DrugStock getDrugStock() {
        return drugStock;
    }

    public void setDrugStock(DrugStock drugStock) {
        this.drugStock = drugStock;
    }

    public Double getMonthUsed() {
        return monthUsed;
    }

    public void setMonthUsed(Double monthUsed) {
        this.monthUsed = monthUsed;
    }

    public String getMinUnit() {
        return minUnit;
    }

    public void setMinUnit(String minUnit) {
        this.minUnit = minUnit;
    }

    public String getBatchNo() {
        return batchNo;
    }

    public void setBatchNo(String batchNo) {
        this.batchNo = batchNo;
    }

    public String getSupplierId() {
        return supplierId;
    }

    public void setSupplierId(String supplierId) {
        this.supplierId = supplierId;
    }
}